package org.example.exp2.exam3;

public class EncryptorFactory {
   public static Encryptor getEncryptor(String type) {
      if(type.equals("des")){
         return new DesEncryptor();
      } else if (type.equals("desede")) {
         return new DesedeEncryptor();
      } else if (type.equals("md5")) {
         return new Md5Encryptor();
      } else {
         return null;
      }
   }
}